home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 21 / Cream of the Crop 21 (Terry Blount) (October 1996).iso / bbs / m2d100.zip / MAIL2DIR.TXT < prev   
Text File  |  1996-08-26  |  10KB  |  249 lines

  1. MAIL2DIR - Move mail to spool directory // Absolute Solutions
  2. -------------------------------------------------------------
  3.  
  4.     Copyright 1995, 1996 Mats Wallin; All rights reserved
  5.  
  6.  
  7.     Introduction
  8.     ------------
  9.  
  10.         MAIL2DIR is a utility that moves all mail and files that are
  11.         addressed to listed systems to a specified directory. It can
  12.         for instance be used to move mail to a point over a network,
  13.         or to move mail to systems that wish to pick it up via FTP.
  14.  
  15.         MAIL2DIR scans FrontDoor's netmail directory to find the mail
  16.         and files that are waiting to be sent to the specified
  17.         systems. When doing this, it honors all the flags and
  18.         attributes that FrontDoor uses.
  19.  
  20.         MAIL2DIR is fully integrated with FrontDoor, and reads
  21.         FrontDoor's configuration files to get the needed
  22.         information. It does also use FrontDoor's semaphore files to
  23.         prevent any problems.
  24.  
  25.  
  26.     How to use it
  27.     -------------
  28.  
  29.         When using MAIL2DIR with the commercial version of FrontDoor,
  30.         MAIL2DIR requires that you have a task number defined it for,
  31.         that isn't used by a running FrontDoor line. If you are using
  32.         MAIL2DIR in your normal .BAT file, this shouldn't be a
  33.         problem, but if you do use MAIL2DIR by itself, please make
  34.         sure that you either don't have TASK set, or that it is set to
  35.         a unused TASK number.
  36.  
  37.         When running MAIL2DIR, you can specify a number of
  38.         parameters. The only required parameters are the destination
  39.         directory to which MAIL2DIR should move the mail and files,
  40.         and a list of systems for which it should do this.
  41.         
  42.  
  43.     Message requirements
  44.     --------------------
  45.  
  46.         MAIL2DIR will process all netmail messages addressed to the
  47.         specified systems, except those that are Sent, Received or
  48.         Locked. It will also ignore all messages with File Request
  49.         status, since it wouldn't be possible to perform a file
  50.         request this way.
  51.  
  52.         By default, MAIL2DIR will also ignore all messages that have
  53.         the Crash or Immediate flag (if the message is created
  54.         locally, i.e. have the Local flag). This can however be
  55.         changed with a command line parameter.
  56.  
  57.  
  58.     Command line format
  59.     -------------------
  60.  
  61.         The command line format for MAIL2DIR is:
  62.  
  63.         MAIL2DIR [switches] <Dir> <Address1> [<Address2> [...]]
  64.  
  65.  
  66.         switches can be any of the following (all switches can be
  67.         abbreviated to the shortest unique name, which is the
  68.         uppercase part of the name in the list below).
  69.  
  70.         /CRashok       - If you want MAIL2DIR to process messages 
  71.                          that have Crash or Immediate status, use this
  72.                          switch.
  73.  
  74.         /IFExist=mask  - MAIL2DIR will only process mail for the
  75.                          specified systems if a file that matches the
  76.                          specified mask exists, otherwise mail for
  77.                          these systems are skipped.
  78.  
  79.         /IFNotexist=mask
  80.                        - MAIL2DIR will only process mail for the
  81.                          specified systems if there is no file that
  82.                          matches the specified mask, if there is a
  83.                          matching file, mail for the specified systems
  84.                          are skipped.
  85.  
  86.         /CMdfile=file  - If you want MAIL2DIR to process mail for many
  87.                          systems at once, you can use a text file with
  88.                          commands. See the section 'Command file' for
  89.                          more information.
  90.  
  91.         /Logfile=file  - By default, MAIL2DIR writes information to
  92.                          the MAIL2DIR.LOG file in the same directory
  93.                          as FrontDoor's logfile. Use this switch if
  94.                          you want MAIL2DIR to write the loginformation
  95.                          to another file.
  96.  
  97.         /Nologfile     - If you don't want any logfile at all, use
  98.                          this switch.
  99.  
  100.         /Usefdlog      - If you want MAIL2DIR to use the same logfile
  101.                          as FrontDoor, use this switch. MAIL2DIR will
  102.                          then read the name of the file from
  103.                          FrontDoor's configuration.
  104.  
  105.  
  106.         <Dir> is the directory to which MAIL2DIR should move all mail
  107.         and files for the systems specified on the command line.
  108.  
  109.         <Address1>, <Address2>, ... is a list of up to 10
  110.         addresses. MAIL2DIR will move all mail and files addressed to
  111.         one of these addresses to the <Dir> directory.
  112.  
  113.  
  114.     Command file
  115.     ------------
  116.  
  117.         Instead of specifying all information on the command line
  118.         everytime you run MAIL2DIR, it is possible to use a text file
  119.         that contains all the commands.
  120.  
  121.         The command file also has the advantage that you can specify
  122.         that MAIL2DIR should process messages for more than one system
  123.         at once, and therefor reduce the number of times you have to
  124.         run MAIL2DIR.
  125.  
  126.         The command file is a standard text file, that can contain
  127.         empty lines and comments. Comments can occur anywhere in the
  128.         file, and should start with a semicolon (;).
  129.  
  130.         Each line in the file should contain a complete definition for
  131.         which systems mail that should be moved, and to where it
  132.         should be moved. The lines should have exactly the same format
  133.         as the command line, with the exception that they should not
  134.         begin with MAIL2DIR (i.e. the program name).
  135.  
  136.         If you specified any switches on the command line together
  137.         with the /CmdFile switch, these switches are default for all
  138.         lines in the command file. You can however not specify a <Dir>
  139.         or any <Address?> parameters on the command line, together
  140.         with the /CmdFile switch.
  141.  
  142.         You can not use the /LogFile, /NoLogFile, /UseFDLog or
  143.         /CmdFile switches in the command file. If you do, they will
  144.         just be ignored.
  145.  
  146.         If you use the /IfExist or the /IfNotExist switch in the
  147.         command file, they do only apply to the systems specified on
  148.         the same line.
  149.  
  150.         If you use the /IfExist or the /IfNotExist switch on the
  151.         command line together with the /CmdFile switch, the specified
  152.         filemasks are checked for all systems in the command file.
  153.  
  154.  
  155.     Examples of a command file
  156.     --------------------------
  157.  
  158.         To clarify how the command file works, here is an example of
  159.         one:
  160.  
  161.         C:\OUT\MYPOINT   2:270/19.1 255:3352/3 /CrashOk
  162.         X:\FILE\FTP\MATS 2:201/329 /IfNotExist=X:\FILE\FTP\MATS\*.BSY
  163.         X:\FILE\FTP\BRUCE 1:170/400 /IfExist=Y:\SEMAPHOR\GETMAIL.NOW
  164.  
  165.         The three lines above will tell MAIL2DIR to do the following:
  166.  
  167.         1) Copy all mail and files that are addressed to 2:270/19.1
  168.            and 255:3352/3 to the C:\OUT\MYPOINT\ directory, including
  169.            messages and files that have Crash or Immediate status.
  170.  
  171.         2) Copy all mail to 2:201/329 to the X:\FILE\FTP\MATS\
  172.            directory, but only if there are no file with the extension
  173.            .BSY in the X:\FILE\FTP\MATS\ directory.
  174.  
  175.         3) Copy all mail to 1:170/400 to the X:\FILE\FTP\BRUCE\
  176.            directory, but only if there is a file with the name
  177.            GETMAIL.NOW in the Y:\SEMAPHOR\ directory.
  178.  
  179.         Assuming that the command file above is named MAIL2DIR.CMD, it
  180.         can be used with the following command:
  181.  
  182.         MAIL2DIR /CMDFILE=MAIL2DIR.CMD
  183.            
  184.  
  185.     The KFS, TFS status
  186.     -------------------
  187.  
  188.         MAIL2DIR does support the KFS (Kill file after it has been
  189.         sent) and TFS (Truncate file after it has been sent)
  190.         attributes. MAIL2DIR processes these attributers after it has
  191.         copied all the files. If there is no remaining file attaches
  192.         for a file that has been copied, the file is deleted or
  193.         trun